package com.zfl.pojo;

import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.groups.Default;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ToString
public class Category {
    @NotNull(groups = Update.class)
    private Integer id;
    @NotEmpty
    private String categoryName;
    @NotEmpty
    private String categoryAlias;//分类别名
    private Integer createUser;//创建时间
    private Long createTime;//创建时间
    private Long updateTime;//修改时间

    //不指定属于default分组
    //分组可以继承

    public interface Add extends Default {

    }

    public interface Update extends Default{

    }
}
